def universal_decorator(func):
    """
    通用装饰器实现
    :param func:
    :return:
    """

    def in_function(*args, **kwargs):
        print("开始装饰-----------------")
        func(*args, **kwargs)
        print("装饰结束-----------------")

    return in_function


@universal_decorator
# decorator_test = universal_decorator(decorator_test)
def decorator_test(number):
    print("装饰器方法测试执行打印", number)


if __name__ == '__main__':
    decorator_test(2)
